package com.example.netty;

import io.netty.channel.Channel;

public class StartClient {
	
	public static void main(String[] args) throws Exception {
		
		 NettyClient client = new NettyClient("127.0.0.1", 48411);
//		 NettyClient client = new NettyClient("172.19.44.30", 48415);
	        //启动client服务
	        client.start();
	 
	        Channel channel = client.getChannel();
	        String msg = "上报数据PM2.5,1,PM10,11";
	        //channel对象可保存在map中，供其它地方发送消息
	        channel.writeAndFlush(msg);
	        
		
	}
	

}
